package cn.bluedot.model;

import java.math.BigDecimal;
import java.util.Date;

import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotNull;

import org.springframework.format.annotation.DateTimeFormat;

import cn.bluedot.valid.StorageRecordVG;

public class StorageRecord {
    private Long id;
    
    @NotNull(groups=StorageRecordVG.class)
    private Long resId;
    
    @NotNull(groups=StorageRecordVG.class)
    @DecimalMin(groups=StorageRecordVG.class, value="0.1")
    private BigDecimal price;//
    
    @NotNull(groups=StorageRecordVG.class)
    @DecimalMin(groups=StorageRecordVG.class, value="0.1")
    private BigDecimal inNumber;//
    private String standard;//

    private BigDecimal totalPrice;
    private Long inPersonId;
    
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date inTime;

    private BigDecimal curNumber;
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date mtime;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getResId() {
        return resId;
    }

    public void setResId(Long resId) {
        this.resId = resId;
    }

    public BigDecimal getPrice() {
        return price;
    }

    public void setPrice(BigDecimal price) {
        this.price = price;
    }

    public BigDecimal getInNumber() {
        return inNumber;
    }

    public void setInNumber(BigDecimal inNumber) {
        this.inNumber = inNumber;
    }

    public String getStandard() {
        return standard;
    }

    public void setStandard(String standard) {
        this.standard = standard;
    }

    public BigDecimal getTotalPrice() {
        return totalPrice;
    }

    public void setTotalPrice(BigDecimal totalPrice) {
        this.totalPrice = totalPrice;
    }

    public Long getInPersonId() {
        return inPersonId;
    }

    public void setInPersonId(Long inPersonId) {
        this.inPersonId = inPersonId;
    }

    public Date getInTime() {
        return inTime;
    }

    public void setInTime(Date inTime) {
        this.inTime = inTime;
    }

    public BigDecimal getCurNumber() {
        return curNumber;
    }

    public void setCurNumber(BigDecimal curNumber) {
        this.curNumber = curNumber;
    }

    public Date getMtime() {
        return mtime;
    }

    public void setMtime(Date mtime) {
        this.mtime = mtime;
    }
}